//
//  BillCell.m
//  ScalperMerchant
//
//  Created by 王云 on 2017/10/6.
//  Copyright © 2017年 WY. All rights reserved.
//

#import "BillCell.h"

@implementation BillCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}
- (void)setDic:(NSDictionary *)Dic{
    _Dic = Dic;
    
    NSString *time = [HWCommon getTimeStr:[_Dic hw_safeObjectForKey:@"usetime"] format:@"MM-dd HH:mm"];
    _topData.text = [[time componentsSeparatedByString:@" "] firstObject];
    _bottomData.text = [[time componentsSeparatedByString:@" "] lastObject];
    
    [_imgIcon sd_setImageWithURL:[NSURL URLWithString:[_Dic hw_safeObjectForKey:@"member_avatar"]] placeholderImage:[UIImage imageNamed:@"logo"]];
//    _imgIcon.image = [UIImage imageNamed:@"logo"];
    
    _nameL.text = [_Dic hw_safeObjectForKey:@"member_name"];
    
    _priceL.text = [NSString stringWithFormat:@"%.2f",[[_Dic hw_safeObjectForKey:@"goods_marketprice"] floatValue]];
    
    _couponL.text = [NSString stringWithFormat:@"%@",[_Dic hw_safeObjectForKey:@"code"]];
}


@end
